'''
介绍:我的实验模块重置接口测试
作者:安雨杰
'''
import unittest
from parameterized import parameterized

from pages.page_login import PageLogin
from pages.page_my_experiment import PageSell
from utils.reader import Reader


class SellTest(unittest.TestCase):
    """
    我的实验模块
    """
    @classmethod
    def setUpClass(cls) -> None:
        cls.sell = PageSell()
        if not Nav().is_login():
            login = PageLogin()
            login.open()
            login.do_login()
    @parameterized.expand(Reader.read_csv('sell_data.csv'))
    def test_Reset(self, experimentCode, status, experimentType, experimentName):
        """
        重置实验功能测试
        """
        self.sell.open()
        self.sell.reset_experiment( experimentCode,status,experimentType,experimentName)
        # todo 断言
        # data = self.sell.get_product_data()
        # for item in data:
        #     self.assertEqual(barcode, item[0])



